package com.yc.yyds.servlet;

import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.annotation.*;
import java.io.IOException;

import com.google.gson.Gson;
import com.yc.yyds.Bean.Result;
import com.yc.yyds.dao.ArrangeDao;

@WebServlet(name = "RemoveArrangeServlet", value = "/RemoveArrangeServlet.s")
public class RemoveArrangeServlet extends HttpServlet {
    ArrangeDao dao=new ArrangeDao();
    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
        String ppjhid = request.getParameter("ppjhid");
        dao.remove(ppjhid);
        String s = new Gson().toJson(new Result(1, "删除成功", null));
        response.getWriter().append(s);
    }

    @Override
    protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {

    }
}
